const fs = require("fs");
const path = require("path");
// 读取info.json 并转为数组
const res = fs.readFileSync(path.join(__dirname, "./info.json"), "utf8");
// console.log(res);
const a = JSON.parse(res)
console.log(a);

const b = Math.floor(Math.random()*a.length);

a[b] = + a[b]

fs.writeFileSync(path.join(__dirname, "./info.json"), JSON.stringify(a))